package com.ruoyi.business.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.business.domain.Course;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

public interface CourseMapper extends BaseMapper<Course> {
    /**
     * 查询课程列表
     *
     * @param course 课程
     * @return 课程集合
     */
    public List<Course> selectCourseList(Course course);

    public List<Course> selectAllCourseList();

    public List<Course> selectCourseByVenueId(long venueId);

    public List<Course> selectCourseByCoachId(long coachId);

    public List<Course> selectCourseListByCoachIdAndTime(Course course);

    public List<Course> selectCourseListByCoachId(Course course);

    public List<Course> selectCourseByNameAndStartDate(Course course);

    public Course selectCourseBySortAndStartDate(Course course);

    public List<Course> selectCourseByTimeRange(@Param("startTime") String startTime, @Param("endTime") String endTime);


    public Course selectCourseById(Long id);

    /**
     * 更新课程数据
     *
     * @param course 课程
     */

    public int insertCourse(Course course);

    /**
     * 更新课程数据
     *
     * @param course 课程
     */

    public int updateCourse(Course course);

    public List<Course> selectBannerCourse();

    public List<Course> selectCourseByDateAndType(Course course);

    public int deleteCurseByIds(Long[] ids);
}
